package com.citycloud.ccuap.tc.admin.projectdgrolerel;

import com.citycloud.ccuap.framework.service.mybatis.MybatisServiceImpl;
import com.citycloud.ccuap.tc.admin.entity.SysProjectDgRoleRel;
import com.citycloud.ccuap.tc.admin.repository.SysProjectDgRoleRelRepository;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 数据角色关联表业务处理实现
 * @author sufeng
 *
 */
@Service
public class ProjectDgRoleRelService extends MybatisServiceImpl<SysProjectDgRoleRelRepository, SysProjectDgRoleRel, String> implements IProjectDgRoleRelService {

    @Override
    public void deleteByDatagroupId(String objId) {
        repository.deleteByDatagroupId(objId);
    }

    @Override
    public void deleteByRoleId(Long roleId) {
        repository.deleteByRoleId(roleId);
    }

    @Override
    public List<SysProjectDgRoleRel> findByRoleId(Long roleId) {
        return repository.findByRoleId(roleId);
    }
}